/**
 * @Author:Geln Yang
 * @Created:2008-7-27
 * $ Revision: 1.0 $
 * $ Author: Geln Yang $
 * $ Date: 2008-7-27 $
 */
package org.geln.web.filter;

import java.io.IOException;

import javax.servlet.Filter;
import javax.servlet.FilterChain;
import javax.servlet.FilterConfig;
import javax.servlet.ServletException;
import javax.servlet.ServletRequest;
import javax.servlet.ServletResponse;
import javax.servlet.http.HttpServletResponse;

/**
 * @Author:Geln Yang
 * @Created:2008-7-27
 */
public class BlockFilter implements Filter {

	public void init(FilterConfig config) throws ServletException {
	}

	public void doFilter(ServletRequest request, ServletResponse response, FilterChain chain) throws IOException,
			ServletException {
		HttpServletResponse rsp = (HttpServletResponse) response;
		rsp.sendError(HttpServletResponse.SC_FORBIDDEN);
	}

	public void destroy() {
	}

	public FilterConfig getFilterConfig() {
		return null;
	}

	public void setFilterConfig(FilterConfig config) {
	}

}
